package com.hjw.java.interface_work;

/**
 * 火柴类
 * @author hjwStrart
 * @create 2022-01-13 17:41
 */
public class Matches implements Ignite{

    private Boolean flag = true;
    @Override
    public void ignite() {
        if (flag) {
            System.out.println("火柴已点亮，正在燃烧。。。。。");
            flag = false;
        }else{
            System.out.println("火柴已燃尽。。。。。");
        }
    }
}
